package com.fuze.energy.controller;

import com.fuze.energy.common.Result;
import com.fuze.energy.domain.entity.RmuCollector;
import com.fuze.energy.service.EMService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@Api(tags = "设备管理API")
@Slf4j
@RestController
@RequiredArgsConstructor
public class EMController {

    @Autowired
    EMService emService;

    @ApiOperation("设备管理信息查看")
    @GetMapping(value = "/equipment")
    public Result equipmentManagement() {
        List<RmuCollector> collectorList= emService.queryEquipment();
        return Result.ok(collectorList);
    }
}
